package com.QBsoft.spring.service.impl;

import com.QBsoft.spring.gestor.IWsGestor;
import com.QBsoft.spring.service.IWsService;
/**
 * 
 * @author aquingaluisa
 *
 */
public class WsService implements IWsService {
	private IWsGestor wsGestor;
	public IWsGestor getWsGestor() {
		return wsGestor;
	}
	public void setWsGestor(IWsGestor wsGestor) {
		this.wsGestor = wsGestor;
	}
	@Override
	public String devolverProducto() throws Exception {
		
		return wsGestor.devolverProducto();
	}
	@Override
	public String devolverDisponibles(String fechaInicio, String fechaFin, String fincas)
			throws Exception {
		return wsGestor.devolverDisponibles(fechaInicio, fechaFin, fincas);
	}
	@Override
	public String devolverPK(String nombreTabla,String codigoPk)throws Exception{
		return wsGestor.devolverPK(nombreTabla,codigoPk);
	}
	
	@Override
	public String insertarPedido(String columnasTexto,String shipmentid) throws Exception {
		System.out.println("*********************************************************");
		System.out.println(columnasTexto);
		System.out.println("*********************************************************");
		if(shipmentid==null){
			shipmentid="2";
		}
		return wsGestor.insertarPedido(columnasTexto,shipmentid);
	}
	@Override
	public String getFacturaByOrderId(String tipo, String codigoTipo)throws Exception {
		return wsGestor.getFacturaByOrderId(tipo ,codigoTipo);
	}
	
	
}
